<template>
  <div>
    <MImportData :download="download" :http="uploadHttp"></MImportData>
  </div>
</template>

<script setup lang="ts">
defineOptions({
  name: 'DemoCpnsImportData'
})

const download = () => {
  console.log('下载')
  // return new Promise((resolve) => {
  //   setTimeout(() => {
  //     resolve({})
  //   }, 1000)
  // })
}

const uploadHttp = (formData: FormData) => {
  console.log(formData, 'formData')
  return new Promise<any>((resolve) => {
    setTimeout(() => {
      resolve({
        message: '111111111'
      })
    }, 2000)
  })
}
</script>

<style lang="scss" scoped></style>
